home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 23
/
Aminet 23 (1998)(GTI - Schatztruhe)[!][Feb 1998].iso
/
Aminet
/
dev
/
amos
/
AMOS1097.lzh
/
AMOSLIST
/
000197_amos-request@svcs1.digex.net_Mon Oct 20 18:46:36 1997.msg
< prev
next >
Wrap
Internet Message Format
|
1997-11-02
|
5KB
Received: from svcs1.digex.net (svcs1.digex.net [204.91.197.224])
by mail3.access.digex.net (8.8.5/8.8.5) with ESMTP id SAA22239
for <mcox@access.digex.net>; Mon, 20 Oct 1997 18:46:35 -0400 (EDT)
Received: (from daemon@localhost)
by svcs1.digex.net (8.8.5/8.8.5) id OAA10211
for amos-out; Mon, 20 Oct 1997 14:51:58 -0400 (EDT)
Received: from mail3.access.digex.net (mail3.access.digex.net [205.197.247.4])
by svcs1.digex.net (8.8.5/8.8.5) with ESMTP id OAA10208
for <amos-list@svcs1.digex.net>; Mon, 20 Oct 1997 14:51:57 -0400 (EDT)
Received: from leary.huron.net (root@leary.huron.net [205.150.207.2])
by mail3.access.digex.net (8.8.5/8.8.5) with ESMTP id OAA21374
for <amos-list@access.digex.net>; Mon, 20 Oct 1997 14:51:56 -0400 (EDT)
Received: from golden.net (ppp31-ts1-kw.huron.net [205.150.207.80])
by leary.huron.net (8.8.5/8.8.5) with SMTP id OAA00685
for <amos-list@access.digex.net>; Mon, 20 Oct 1997 14:48:16 -0400
From: "Mr. Giark To You" <joehick@golden.net>
To: AMOS List <amos-list@access.digex.net>
Date: Mon, 20 Oct 1997 14:44:41 -0500
Message-ID: <yam7232.2095.4163168@huron.net>
X-Mailer: YAM 1.3.3 - Amiga Mailer by Marcel Beck
Subject: CD32
MIME-Version: 1.0
Content-Type: text/plain
Status: O
X-Status:
'As requested, here is my set of CD32 Pad procedures. Feel free to use them
'for your own programs. The CD32 Pad procedure uses the same values as the
'Joy(X) command for the CD32_TEXT procedure, which allows you to use a
'standard joystick for entry as well.
'Test the test entry procedure
Locate 0,0 : Print "Up/Down to select, Left to delete, Right to enter, Fire
when done"
CD32_TEXT[8,32,20] : TXT$=Param$
Print "text entered: ";TXT$
Wait 60
'Test the CD32 buttons
Do
PAD : CD32=Param
Clw : Home
If CD32 and 1 Then Print "Up ";
If CD32 and 2 Then Print "Down ";
If CD32 and 4 Then Print "Left ";
If CD32 and 8 Then Print "Right ";
If CD32 and 16 Then Print "Red ";
If CD32 and 32 Then Print "Blue ";
If CD32 and 64 Then Print "Green ";
If CD32 and 128 Then Print "Yellow ";
If CD32 and 256 Then Print "Rewind ";
If CD32 and 512 Then Print "Fast Forward ";
If CD32 and 1024 Then Print "Pause ";
Loop
Procedure PAD
PAD:
CD=0 : CD32=0
Lib Open 3,"lowlevel.library",40
Dreg(0)=1
CD=Lib Call(3,-30)
If CD and 1 Then CD32=CD32+%1000 : Rem Right
If CD and 2 Then CD32=CD32+%100 : Rem Left
If CD and 4 Then CD32=CD32+%10 : Rem Down
If CD and 8 Then CD32=CD32+%1 : Rem Up
If CD and 131072 Then CD32=CD32+%10000000000 : Rem Pause
If CD and 262144 Then CD32=CD32+%100000000 : Rem Rewind
If CD and 524288 Then CD32=CD32+%1000000000 : Rem Fast Forward
If CD and 1048576 Then CD32=CD32+%1000000 : Rem Green
If CD and 2097152 Then CD32=CD32+%10000000 : Rem Yellow
If CD and 4194304 Then CD32=CD32+%10000 : Rem Red
If CD and 8388608 Then CD32=CD32+%100000 : Rem Blue
Lib Close 3
End Proc[CD32]
Procedure CD32_TEXT[TX,TY,IN]
CHAR$="" : CHAR=0 : A$="" : IN$="" : PAD=0
'You can add characters to the set by including them in CHAR$
CHAR$="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ,.!?() 1234567890"
CHAR=1
Curs Off
CD32:
'If you have added characters, make sure the 69 is set to the length of
'your character string.
If CHAR<1 Then CHAR=69
If CHAR>69 Then CHAR=1
A$=Mid$(CHAR$,CHAR,1)
B$=IN$+A$+" "
Ink 7,0 : Text TX,TY,B$
CD32A:
Do : PAD=0 : PAD : PAD=Param : If PAD=0 Then Loop
'To use a joystick instead, replace the above line with:
'Do : PAD=Joy(0) : If PAD=0 Then Loop
If Len(IN$)=IN Then Goto CD32A
If PAD and 2 Then CHAR=CHAR-1 : Wait 5 : Goto CD32
If PAD and 1 Then CHAR=CHAR+1 : Wait 5 : Goto CD32
If PAD and 16
IN$=IN$+A$
Text TX,TY,IN$
Goto CD32B
End If
If PAD and 4 Then IN$=Left$(IN$,Len(IN$)-1) : Wait 15 : Goto CD32
If PAD and 8 Then IN$=IN$+A$ : Wait 10 : Goto CD32
Goto CD32A
CD32B:
End Proc[IN$]
'TX and TY are graphic coordinates for the text. IN is the allowed length of
'the string to be entered. The text procedure returns the string as a
parameter
'and uses the PAD procedure for its input.
'Up scrolls forward through the character set. Down scrolls back through the
'character set. Left deletes the current character. Right moves to the next
'character. Red (Fire) ends input.
Well met and godspeed,
Giark
joehick@golden.net
http://www.golden.net/~joehick/fbn/index.html
______ ______ _____ .------------------------------------------.
/ ____/ / __ / / ___ \ ! AMOS games, utilities, demos, etc. !
/ /__ / /_/ / / / / / ! !
/ ___/ / ___ | / / / / ! CyberSpace BBS (519)579-0072 !
/ / / /__/ / / / / / ! on A2000 060/50MHz (519)579-0173 !
/_/ /______/ /_/ /_/ ! !
Fly By Nite Videe-Oh! ! FBN Amiga 500 020 14MHz 1C/5F RAM 3.1OS !
IAPA Member `------------------------------------------'